package com.irdstudio.apicenter.console.service.authenticate;

import java.sql.SQLException;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.irdstudio.apicenter.console.dm.AppSaleSite;
import com.irdstudio.apicenter.console.dm.AppSaleSiteDao;

@Service(value = "appSaleSiteService")
public class AppSaleSiteService {

	@Autowired
	private AppSaleSiteDao appSaleSiteDao;

	public int insertOne(AppSaleSite appSaleSite) throws SQLException,
			ClassNotFoundException {
		return appSaleSiteDao.save(appSaleSite);
	}

	public AppSaleSite queryAppTradePrivate(String saleSiteId)
			throws SQLException {
		return appSaleSiteDao.queryWithKeys(saleSiteId);
	}

	public int update(AppSaleSite appSaleSite) throws SQLException,
			ClassNotFoundException {
		return appSaleSiteDao.update(appSaleSite);
	}

	public int delete(AppSaleSite appSaleSite) throws SQLException,
			ClassNotFoundException {
		return appSaleSiteDao.delete(appSaleSite);
	}

}
